package com.czy.form.model;

import lombok.Data;

import javax.persistence.*;
import java.util.List;

/***
 * @ ClassName: FormData
 * @ Description: TODO
 * @ author：libi
 * @ date： 2020/2/1 13:11
 * @ version： V1.0.0
 * @ CopyRight：czy
 */
@Entity
@Table(name = "form_data", schema = "form")
@Data
public class FormData extends FormMeta{

    @Column(name = "form_id", columnDefinition = "varchar(36) comment 'form外键'")
    String formId;

    @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER)
    @JoinColumn(name = "data_id")
    List<FormDataItem> items;


}
